package com.dl.mood.dao;

import androidx.room.Dao;
import androidx.room.Insert;
import androidx.room.Query;

import com.dl.mood.model.MoodItem;

import java.util.List;

@Dao
public interface MoodDao {
    @Query("SELECT * FROM mood_items")
    List<MoodItem> getAllMoodItems();

    @Insert
    void insertMoodItem(MoodItem moodItem);

    // 修改为使用 @Query 注解执行删除所有记录的 SQL 语句
    @Query("DELETE FROM mood_items")
    void deleteAll();

}
